import json

from simple_ddl_parser import DDLParser

ddl = """
CREATE TABLE Persons (
    PersonID int,
    LastName varchar(255),
    FirstName varchar(255),
    Address varchar(255),
    City varchar(255)
);

CREATE TABLE test001 (
    id int,
    name varchar(255)
);

"""

result = DDLParser(ddl).run()

# 把字典转换成json串
json_data = json.dumps(result)

print(json_data)
